package org.concepts.java.core.concurrency.executor;

import java.util.concurrent.Callable;

/**
 * Takes a list of number and sort it.
 * 
 * @author vvvv
 * 
 */
public class SortNumberCallable implements Callable<int[]> {

  private int[] input;

  public SortNumberCallable(int[] input) {
    this.input = input;
  }

  @Override
  public int[] call() throws Exception {
    System.out.println("In Thread [" + Thread.currentThread() + "] id ["
        + Thread.currentThread().getId() + "]");
    return new BubbleSort().sort(this.input);
  }
}
